package com.gzh.controller;


import com.gzh.entity.User;
import com.gzh.service.IUserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author gzh
 * @since 2022-05-20
 */
@RestController
@RequestMapping("/user")
public class UserController {
    @Autowired
    IUserService userService;

    @RequestMapping("list")
    public List<User> list(){
        List<User> list = userService.list();
        return  list;
    }
}
